<template>
	<view class="container">
		<Navigator2 :title="$t('device.selectDeviceType')"></Navigator2>
		<view class="products">
			<view class="product" @click="naviToGuidePage">
				<view class="product-img">
					<image src="/static/product1.png"></image>
				</view>
				<view class="product-name">
					<text>{{ $t('device.AI智能机器人') }}</text>
				</view>
			</view>
			<view class="product" @click="naviToGuidePage">
				<view class="product-img">
					<image src="/static/product2.png"></image>
				</view>
				<view class="product-name">
					<text>{{ $t('device.智能学习平板') }}</text>
				</view>
			</view>
			<view class="product" @click="naviToGuidePage">
				<view class="product-img">
					<image src="/static/product3.png"></image>
				</view>
				<view class="product-name">
					<text>{{ $t('device.智能故事熊') }}</text>
				</view>
			</view>
			<view class="product" @click="naviToGuidePage">
				<view class="product-img">
					<image src="/static/product4.png"></image>
				</view>
				<view class="product-name">
					<text>{{ $t('device.编程学习机器人') }}</text>
				</view>
			</view>
			<view class="product" @click="naviToGuidePage">
				<view class="product-img">
					<image src="/static/product5.png"></image>
				</view>
				<view class="product-name">
					<text>{{ $t('device.智能音乐玩具') }}</text>
				</view>
			</view>
			<view class="product" @click="naviToGuidePage">
				<view class="product-img">
					<image src="/static/product6.png"></image>
				</view>
				<view class="product-name">
					<text>{{ $t('device.AI绘画板') }}</text>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import Navigator2 from '@/components/Navigator2.vue'
	export default {
		data() {
			return {
				
			}
		},
		methods: {
			naviToGuidePage() {
				uni.navigateTo({
					url: '/pages/device/devicesettingguide'
				})
			}
		},
		components: {
			Navigator2
		}
	}
</script>

<style lang="scss" scoped>
.container {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: #F1F2F5;
	
	.products {
		display: grid;
		grid-template-columns: 1fr 1fr;
		gap: 16px;
		padding: 16px;
		
		.product {
			background-color: #FFFFFF;
			border-radius: 16px;
			padding: 24px 16px;
			display: flex;
			flex-direction: column;
			align-items: center;
			box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
			
			.product-img {
				margin-bottom: 16px;
				
				image {
					width: 120px;
					height: 120px;
					object-fit: contain;
				}
			}
			
			.product-name {
				text-align: center;
				
				text {
					color: #1F2937;
					font-size: 14px;
					line-height: 20px;
				}
			}
		}
	}
}
</style>
